interface User {
  age: number;
  name: string;
}

let u1: Partial<User>;

u1 = {
  age: 11,
};

let ue: Exclude<"A" | "B" | "C" | "D", "B" | "C">; // 剔除B C 类型

let uex: Extract<"A" | "B" | "C" | "D", "B" | "C" | "E" | "F">; // 提取

class Func {}
// 约束一个构造函数
type twoParamsConstuctor = new (arg1: any, arg2: any) => Func;
const B: twoParamsConstuctor = class Test {
  constructor(a: any, b: any) {} // 可以多不可以少，创建的对象和User一样，都是空对象
};

type Inst = InstanceType<twoParamsConstuctor>; // Func
